package org.example.designPattern.behavioral.chain;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

/*
* 责任链模式：将请求请求沿着处理链传递，直到被处理
* */
public class ChainTest {
    public static void main(String[] args) {
        List<String> urls = new ArrayList<>();
        urls.add("15454.png");
        urls.add("21548.zip");
        urls.add("154783.zip");

        ZipProcessor zipProcessor = new ZipProcessor();
        PngProcessor pngProcessor = new PngProcessor(zipProcessor);
        pngProcessor.process(urls);
    }
}
